package com.andyliu.system.service.impl;

import com.andyliu.system.entity.UserRole;
import com.andyliu.system.mapper.UserRoleMapper;
import com.andyliu.system.service.IUserRoleService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;

/**
 * <p>
 * 用户和角色关联表 服务实现类
 * </p>
 *
 * @author andyLiu
 * @since 2021-08-10
 */
@Service
public class UserRoleServiceImpl extends ServiceImpl<UserRoleMapper, UserRole> implements IUserRoleService {
    @Autowired
    private UserRoleMapper userRoleMapper;

      public  IPage<UserRole> selectByPage(Integer pageNumber,Integer pageSize, UserRole userRole){
        return userRoleMapper
                .selectByPage(new Page<UserRole>(pageNumber,pageSize),userRole);
      }

}
